<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    <script type="text/javascript" src="login/scripts/jquery-1.3.2.min.js"></script>
	<script type="text/javascript" src="scripts/common.js"></script>
	<link rel="stylesheet" type="text/css" href="login/css/style.css" />
	<link rel="stylesheet" type="text/css" href="login/css/theme1.css" />
<style type="text/css">
td {
	border: none;
}

fieldset {
	display: block;
	padding: 5px 10px 5px 10px;
	line-height: 20px;
	margin-bottom: 10px;
	border: 1px solid #d9e6f0;
	margin-left: 10px;
}

fieldset legend {
	border: 1px solid #d9e6f0;
	background: #fff url(img/form_blue.gif) repeat-x center left;
	color: #375b91;
	font-size: 12px;
	font-weight: bold;
	margin-bottom: 5px;
	padding: 3px;
	width: 150px;
}
</style>
<SCRIPT type="text/javascript">
var soundName = "";
function uploadWindow(){
    var message = "预警声音上传";
    var win = window.showModalDialog("login/upload.jsp" ,message,"dialogWidth=325px;dialogHeight=100px;center=yes;status=no");
    if(win!=null ){
         soundName=win;
         document.getElementById("soundLink").href="resources/disasterUpload/"+soundName;
         document.getElementById("soundLink").innerHTML=soundName;
         document.getElementById("soundValue").setAttribute("value",soundName);
         
   } else{
         alert( "上传失败" );
   }
}
	function playMusic(src){
		var window = new Object();
        window.mc=src;
		showModalDialog("<%=basePath%>/login/music_window.jsp",window,"dialogWidth:250px; dialogHeight:100px;status:no;help:yes");
	}
</SCRIPT>
</head>
<body>
<div id="wrapper" style="margin-top: 10px;">
	<div id="content">
    <form method="post" action="warnReportAction!warnSoundSet.action">
		<div id="box">
			<div>
				<h3>
					当前设置&nbsp;:&nbsp;系统设置&nbsp;>>&nbsp;预警声音设置
				</h3>
			</div>
			<fieldset id="personal">
			  	<legend>
					预警声音设置
				</legend>
				<table border="0x" cellpadding="0" cellspacing="3" class=".tab_table">
				  <tr>
				    <td><a id="soundLink" href="<%=basePath%>/resources/disasterUpload/${warnSoundName}">${warnSoundName}</a>&nbsp;
				    <input id="soundValue" type="hidden" name="warnSoundName" value="${warnSoundName}"/>
				    <a href="javascript:playMusic(document.getElementById('soundValue').value);"><img alt="mod.mp3" src="<%=basePath%>/login/img/wmp.png" width="20" height="20"></a></td>
			      </tr>
				  <tr>
				    <td><input type="button" onclick="uploadWindow()" value="上传"/></td>
			      </tr>
				</table>
			</fieldset>
			<br/>
			<center><input type="submit" value="提交"/></center>
				<br/>
		</div>
        </form>
	</div>
</div>
</body>
</html>